package com.dc.designPattern._0_设计原则._2_ocp.step2;

/**
 * Description: 开闭原则_最终方案_Client
 * @author: gdc
 * @date: 2021/7/23
 * @version 1.0
 */
public class Client {
    public static void main(String[] args) {
        GraphicEditor graphicEditor = new GraphicEditor();
        graphicEditor.drawShape(new Rectangle());
        graphicEditor.drawShape(new Circle());
        graphicEditor.drawShape(new Triangle());

        // 新增图形
        graphicEditor.drawShape(new OtherGraphic());
    }
}









